package com.gitee.demo.param.common;

/**
 * @author Tao on 2020/7/29
 */
public class QuanMinErrorCode
{
    public static final QuanMinErrorCode NULL = create("NULL", "-9999999");
    public static final QuanMinErrorCode SUCCESS = create("SUCCESS", "0");
    public static final QuanMinErrorCode ERROR_SYS = create("系统异常", "100001");
    public static final QuanMinErrorCode ERROR_PARAM = create("参数错误", "100002");
    public static final QuanMinErrorCode ERROR_SIGN = create("签名验证失败", "1111004");
    public static final QuanMinErrorCode ERROR_NO_EXIST = create("订单号不存在", "1111008");
    public static final QuanMinErrorCode ERROR_SERVER = create("服务繁忙,请重试.", "500");
    public static final QuanMinErrorCode CARD_ERROR = create("绑卡信息失败.", "100003");

    private String code;
    private String msg;

    public static QuanMinErrorCode create(String errorMsg, String errorCode) {
        return new QuanMinErrorCode(errorCode, errorMsg);
    }

    public QuanMinErrorCode(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return this.code;
    }

    public String getMsg() {
        return this.msg;
    }
}
